<%@ Page Language="VB" Inherits="CMS" Title="Sitemap" MasterPageFile="~/userfiles/mastercms.master" %>
<%@ import Namespace="System.Xml" %>

<%@ import Namespace="System.IO" %>
<script runat="server">
    'Version 05.06.2007 DH Pfad zu Userfiles/Sitemaps angepasst
   
    Protected Sub Page_PreInit(ByVal sender As Object, ByVal e As System.EventArgs)
        Dim dview As DataView = Nothing
        Dim drv As DataRowView = Nothing
        
        'Anfang Sprachunterstützung
        Dim language As String = ""
        Dim sitemapdatas As SiteMapDataSource
        Dim wobinich As SiteMapPath
        
        language = Request.QueryString("site")
        If GetcookieLanguage() <> "" Then
            sitemapdatas = CType(Master.FindControl("SiteMapDataSource1"), SiteMapDataSource)
            If Not sitemapdatas Is Nothing Then
                sitemapdatas.SiteMapProvider = GetcookieLanguage() & "-sitemap"
            End If
            'wobinich
            wobinich = CType(Master.FindControl("SiteMapPath1"), SiteMapPath)
            If Not wobinich Is Nothing Then
                wobinich.SiteMapProvider = GetcookieLanguage() & "-sitemap"
            End If
        End If
        If language <> "" Then
            sitemapdatas = CType(Master.FindControl("SiteMapDataSource1"), SiteMapDataSource)
            If Not sitemapdatas Is Nothing Then
                sitemapdatas.SiteMapProvider = language & "-sitemap"
            End If
            wobinich = CType(Master.FindControl("SiteMapPath1"), SiteMapPath)
            If Not wobinich Is Nothing Then
                wobinich.SiteMapProvider = language & "-sitemap"
            End If
            SetCookieLanguage(language)
        End If
        'Ende Sprachunterstützung
        
    End Sub
    
    Sub Page_Load(ByVal sender As Object, ByVal e As EventArgs)
    
    End Sub
    

</script>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
        <div class="page-header">
        <h1>Sitemap</h1>
    </div>
    <asp:ListView runat="server" ID="blog2"
        GroupItemCount="4" DataSourceID="AccessDataSource1" >
        <LayoutTemplate>
            <div class="panel panel-default">
                <div class="panel-heading">
                    <asp:DataPager ID="DataPager1" runat="server" PageSize="12" class="btn-group pager-buttons">
                        <Fields>
                            <asp:NextPreviousPagerField ShowLastPageButton="False" ShowNextPageButton="False" ButtonType="Button" ButtonCssClass="btn" RenderNonBreakingSpacesBetweenControls="false" />
                            <asp:NumericPagerField ButtonType="Button" RenderNonBreakingSpacesBetweenControls="false" NumericButtonCssClass="btn" CurrentPageLabelCssClass="btn disabled" NextPreviousButtonCssClass="btn" />
                            <asp:NextPreviousPagerField ShowFirstPageButton="False" ShowPreviousPageButton="False" ButtonType="Button" ButtonCssClass="btn" RenderNonBreakingSpacesBetweenControls="false" />
                        </Fields>
                    </asp:DataPager>
                </div>
                <div class="panel-body">
                    <div class="row" runat="server" id="groupPlaceholder">
                    </div>

                </div>
                <div class="panel-footer">
                    <asp:DataPager ID="DataPager" runat="server" PageSize="12" class="btn-group pager-buttons">
                        <Fields>
                            <asp:NextPreviousPagerField ShowLastPageButton="False" ShowNextPageButton="False" ButtonType="Button" ButtonCssClass="btn" RenderNonBreakingSpacesBetweenControls="false" />
                            <asp:NumericPagerField ButtonType="Button" RenderNonBreakingSpacesBetweenControls="false" NumericButtonCssClass="btn" CurrentPageLabelCssClass="btn disabled" NextPreviousButtonCssClass="btn" />
                            <asp:NextPreviousPagerField ShowFirstPageButton="False" ShowPreviousPageButton="False" ButtonType="Button" ButtonCssClass="btn" RenderNonBreakingSpacesBetweenControls="false" />
                        </Fields>
                    </asp:DataPager>
                </div>
            </div>
        </LayoutTemplate>

        <GroupTemplate>
            <div class="row" runat="server">
                <div class="col-xs-6 col-sm-3" runat="server" id="itemPlaceholder"></div>

            </div>
        </GroupTemplate>
        <ItemTemplate>
            <div class="col-xs-6 col-sm-3" runat="server">
                <div class="thumbnail">
                    <div class="caption">
                        <h3>
                            <asp:Label ID="Label1" runat="server" Text='<% #Eval("titel")%>'></asp:Label></h3>
                        <p>
                            <asp:Label ID="Label2" runat="server" Text='<% #Eval("metadescription")%>'></asp:Label>
                        </p>
                        <p>
                            <asp:HyperLink ID="HyperLink1" runat="server"
                                Target="_blank" Text='<% #Eval("linktext")%>'
                                NavigateUrl='<% #Eval("linkurl")%>' />
                        </p>
                    </div>
                </div>
            </div>
        </ItemTemplate>
    </asp:ListView>
      <asp:AccessDataSource ID="AccessDataSource1" runat="server" DataFile="~/App_Data/mastercms.mdb" SelectCommand="Select * from tbl_pages where sitemap = True ORDER BY Titel"></asp:AccessDataSource>
</asp:Content>

